<template>
  <div class="smart-nav-test">
    <h1>智能导航系统测试</h1>
    
    <div class="test-section">
      <h2>测试信息</h2>
      <p>当前导航模式: {{ navigationStore.mode }}</p>
      <p>组件状态: {{ componentStatus }}</p>
    </div>

    <div class="test-section">
      <h2>切换导航模式</h2>
      <el-button type="primary" @click="switchToSmartNavigation">
        切换到智能导航系统
      </el-button>
      <el-button @click="switchToClassic">
        切换到经典模式
      </el-button>
    </div>

    <div class="test-section">
      <h2>组件测试</h2>
      <div class="component-test">
        <SmartNavigationSystem />
      </div>
    </div>
  </div>
</template>

<script setup>
import { ref, onMounted } from 'vue'
import { useNavigationStore } from '@/stores/navigation'
import SmartNavigationSystem from '@/components/Navigation/SmartNavigationSystem.vue'

const navigationStore = useNavigationStore()
const componentStatus = ref('加载中...')

const switchToSmartNavigation = () => {
  navigationStore.setMode('smart-navigation')
  console.log('已切换到智能导航系统')
}

const switchToClassic = () => {
  navigationStore.setMode('classic')
  console.log('已切换到经典模式')
}

onMounted(() => {
  componentStatus.value = '已加载'
})
</script>

<style scoped>
.smart-nav-test {
  padding: 20px;
}

.test-section {
  margin-bottom: 30px;
  padding: 20px;
  border: 1px solid #e4e7ed;
  border-radius: 8px;
}

.component-test {
  height: 600px;
  border: 1px solid #e4e7ed;
  border-radius: 8px;
  overflow: hidden;
}
</style>
